package de.fhb.bookingoverview.controller.web.actions;

import de.fhb.bookingoverview.commons.web.HttpRequestActionBase;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * Action to manage a HttpServletRequest.
 * 
 * @author Arvid Grunenberg
 * @date 30.12.2010
 * @version 0.1
 */

public class DoShowBookingsAction extends HttpRequestActionBase {
	
    //    private MainManager manager;

	public DoShowBookingsAction() {
		super();
	}

	/**
     * 
     * @param request - HttpServletRequest, which came from the browser
     * @param response - HttpServletResponse, which is sent back to the browser as answer
	 * @throws ServletException 
     */
    public void perform(HttpServletRequest request, HttpServletResponse response) throws ServletException {
        //        manager = new MainManager();
        //        List<BookingVO> bookings;
        try {
            //            bookings = manager.getBookings();
            //            request.setAttribute("bookings", bookings);
            forward(request, response, "showBookings.jsp");
        } catch (IOException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
	}
	
}